import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [
    // 重定向
    {
        path: '/',
        redirect: "home"
    },
    // 注册
    {
        path: '/ringup',
        name: 'ringup',

        component: () =>
            import("../views/logIn/ringUp.vue")
    },
    {
        path: '/home',
        name: 'home',

        component: () =>
            import("../views/home.vue")
    },
    // 郭斌  二手房路由
    {
        path: '/ershou',
        name: 'ershou',

        component: () =>
            import("../views/ershou.vue")
    },
    // 郭斌  二手房详情页路由
    {
        path: '/xiangqing/:thisid',
        name: 'xiangqing',

        component: () =>
            import("../views/xiangqing.vue")
    },
    {
        path: '/kandian',
        name: 'kandian',
        component: () =>
            import("../views/kandian.vue"),
    },

    {
        path: '/blink',
        name: 'blink',

        component: () =>
            import("../views/blink.vue")
    },
    {
        // 共享办公
        path: '/work',
        name: 'work',

        component: () =>
            import("../views/share/work.vue")
    },
    {
        // 共享办公详情页
        path: '/title',
        name: 'title',

        component: () =>
            import("../views/share/title.vue")
    },
    {
        // 贝壳商业
        path: '/trade',
        name: 'trade',

        component: () =>
            import("../views/commerce/trade.vue")
    },
    {
        path: '/news',
        name: 'news',
        component: () =>
            import("../views/news.vue")
    },

    {
        path: '/buyflow',
        name: 'buyflow',
        component: () =>
            import("../views/buyflow.vue")
    },
    {
        path: '/businessflow',
        name: 'businessflow',
        component: () =>
            import("../views/businessflow.vue")
    },
    {
        path: '/riskmap',
        name: 'riskmap',
        component: () =>
            import("../views/riskmap.vue")
    },
    {
        path: '/avoidguide',
        name: 'avoidguide',
        component: () =>
            import("../views/avoidguide.vue")
    },
    {
        path: '/riskcase',
        name: 'riskcase',
        component: () =>
            import("../views/riskcase.vue")
    },
    {
        path: '/me',
        name: 'me',
        component: () =>
            import("../views/me.vue"),
    },
    // 积分
    {
        path: '/integral',
        name: 'integral',
        component: () =>
            import('@/views/me/integral.vue')
    },
    // 积分详情
    {
        path: '/xiangq',
        name: 'xiangq',
        component: () =>
            import('@/views/me/xiangq.vue')
    },
    // 金融
    {
        path: '/financial',
        name: 'financial',
        component: () =>
            import('@/views/me/financial.vue')
    },
    // 业主
    {
        path: '/owner',
        name: 'owner',
        component: () =>
            import('@/views/me/owner.vue')
    },
    // 装修首页
    {
        path: '/boss',
        name: 'boss',
        component: () =>
            import('../views/trim/1boss.vue')
    },
    // 装修设计
    {
        path: '/plan',
        name: 'plan',
        component: () =>
            import("../views/trim/2plan.vue")
    },
    // 店铺详情
    {
        path: '/shop',
        name: 'shop',
        component: () =>
            import("../views/trim/3shops.vue")
    },
    // 装修详情页
    {
        path: '/content',
        name: 'content',
        component: () =>
            import("../views/trim/4content.vue")
    },
    // 装修规划
    {
        path: '/flow',
        name: 'flow',
        component: () =>
            import("../views/trim/5flow.vue")
    },
    //租房页（赵）
    {
        path: '/zu',
        name: 'zu',
        component: () =>
            import("@/components/zufang/zu.vue")
    },
    //心愿单页
    {
        path: '/xinyuan',
        name: 'xinyuan',
        component: () =>
            import("@/components/zufang/xinyuan.vue")
    },
    //租约页
    {
        path: '/zuyue',
        name: 'zuyue',
        component: () =>
            import("@/components/zufang/zuyue.vue")
    },
    //我是业主页
    {
        path: '/myHome',
        name: 'myHome',
        component: () =>
            import("@/components/zufang/myHome.vue")
    },
    //租房详情页
    {
        path: '/deta',
        name: 'deta',
        component: () =>
            import("@/components/zufang/deta.vue")
    },


    // 404页面
    {
        path: '/*',
        name: 'no',
        component: () =>
            import("../views/no.vue")
    },
]

const router = new VueRouter({
    mode: 'history',
    base: process.env.BASE_URL,
    routes
})

export default router